package cn.gz.ibix.bean;

import java.io.Serializable;
import java.util.Date;
import java.util.HashSet;
import java.util.Set;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * 项目名称：YiDianCan
 * <br>类描述：
 * <br>创建人：htliu
 * <br>创建时间：2017/9/15 13:29
 * <br>修改人:
 * <br>修改时间：2017/9/15 13:29
 * <br>修改备注：
 * <br>@version
 */
@Data
@EqualsAndHashCode(of = "id")
@Accessors(chain = true)
public class Order implements Serializable {

    private static final long serialVersionUID = 1L;
    private long id;

    private String cost;

    private String discountCost;

    private String income;

    private String change;

    private Status status;

    private long waiterID;

    private String tableOrRoom;
    private String extra;

    private String actionExtra;

    private Date bespeakTime;
    private Set<OrderItem> orderItems = new HashSet<>();

    private Date createTime;

    private Date payTime;


    public enum Status {
        /**
         * 正在进行中
         */
        DOING,

        /**
         * 完成结款操作
         */
        DONE,
        /**
         * 下订单后取消
         */
        CANCEL,
        /**
         * 预约
         */
        BESPEAK,
        /**
         * 挂起订单，以后结账
         */
        SUSPEND
    }


}
